package com.loagou.k8sboot.mvc.web;

import com.loagou.k8sboot.mvc.entity.UserDo;
import com.loagou.k8sboot.mvc.mapper.UserMapper;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequiredArgsConstructor
@RequestMapping("user")
public final class UserController {

    final UserMapper userMapper;


    @GetMapping("findAll")
    public List<UserDo> findAll() {
        return userMapper.selectList(null);
    }

}
